package com.example.apollo.controller;

import org.springframework.beans.factory.annotation.Value;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @author LiYuhang
 * @version 0.1
 * @application
 * @Date 2021/12/19 12:36
 */
@RestController
public class TestController {
    @Value(value = "${apollo.test:'默认值'}")
    private String testValue;

    @Value(value = "${apollo.test2:null}")
    private Integer testValue2;

    @RequestMapping()
    public String test() {
        System.out.println(testValue2);
        return testValue + testValue2;
    }

}
